package com.wn.common.pojo;

import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import org.springframework.format.annotation.DateTimeFormat;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.Pattern;
import java.util.Date;

@Data
@AllArgsConstructor
@NoArgsConstructor
@ApiModel(value = "旅行社")
public class TravelAngency {

    @ApiModelProperty(value = "修改的时候才提供id",example = "1")

    private Integer travelId;

    @ApiModelProperty(value = "旅行社名字")
    @NotBlank(message = "旅行社名称不得为空！")
    private String travelName;

    @Pattern(regexp = "^\\d{0,12}$",message = "旅行社电话号码格式错误！")
    private String travelTelephone;

    @ApiModelProperty(hidden = true)
    private String travalPassword;

    @ApiModelProperty(value = "旅行社评分",hidden = true)
    private String travalLevel;

    @ApiModelProperty(value = "旅行社详情")
    private String travalDescription;

    @ApiModelProperty(hidden = true)
    private String travalAreaId;

    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
    private String createTime;

    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
    private Date updateTime;

    @ApiModelProperty(hidden = true, value = "该旅行社状态 0--正常，1--待审核，2--拉黑")
    private String status;

    @ApiModelProperty(hidden = true)
    private Integer isDeleted;

    @ApiModelProperty(hidden = true)
    private Integer createUserId;

    @ApiModelProperty(hidden = true)
    private Integer updateUserId;

    private String areaName;


}
